package com.weipai.springboot.module.dao.impl;

import com.weipai.springboot.model.ReputationHistory;
import com.weipai.springboot.module.dao.ReputationHistoryDao;
import com.weipai.springboot.module.mapper.ReputationHistoryMapper;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Repository;

import java.util.List;

/**
 * @author songmengqiang
 * @create 2018-09-26 17:46
 **/
@Repository
public class ReputationHistoryDaoImpl implements ReputationHistoryDao {

    @Autowired
    private ReputationHistoryMapper reputationHistoryMapper;

    @Override
    public int save(ReputationHistory reputationHistory) {
        return reputationHistoryMapper.insertSelective(reputationHistory);
    }

    @Override
    public List<ReputationHistory> queryByCustomerId(String customerId) {
        return reputationHistoryMapper.queryByCustomerId(customerId);
    }

    @Override
    public int insert(ReputationHistory reputation) {
        return reputationHistoryMapper.insertSelective(reputation);
    }
}
